<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>窗口</title>
    <!--必须要引入的easyUI资源  按顺序引入-->
    <link rel="stylesheet" type="text/css" href="../easyui/themes/default/easyui.css">
    <link rel="stylesheet" type="text/css" href="../easyui/themes/icon.css">
    <script type="text/javascript" src="../easyui/jquery.min.js"></script>
    <script type="text/javascript" src="../easyui/jquery.easyui.min.js"></script>
    <script>
        $(function () {
            $("#window").window({
                width: 300,
                height: 200,
                title: "窗口",
                draggable: false,
                modal: false,
                content: "这是我的第一个easyUI窗口例子",
                onBeforeClose:function () {
                    alert("你真的要关掉我？");
                }
            });

            $("#close").click(function () {
                $("#window").window("close");
            });

            $("#open").click(function () {
                $("#window").window("open");
            });

            $("#max").click(function () {
                $("#window").window("maximize");
            });
        })
    </script>
</head>
<body>
    <div id="window" data-options="iconCls:'icon-save'"></div>
    <button id="open">打开</button>
    <button id="close">关闭</button>
    <button id="max">最大化</button>
</body>
</html>